import { getCategoryList } from '@/api/category';

export const useCategory = async () => {
  const res = await getCategoryList({
    pageSize: 99
  });
  return res.list.map(item => {
    return {
      value: item.categoryId,
      label: item.categoryName,
      disabled: item.categoryCode === 'DEFAULT'
    };
  });
};
